<template>
  <view class="settings-container">
    <!-- 基本信息设置 -->
    <view class="settings-group">
      <view class="group-title">基本信息</view>
      <view class="settings-list">
        <view class="settings-item" @click="navigateTo('/pages/mine/settings/shop-info')">
          <text class="item-label">店铺信息</text>
          <view class="item-right">
            <text class="item-value">{{shopInfo.name}}</text>
            <text class="item-arrow">></text>
          </view>
        </view>
        <view class="settings-item" @click="navigateTo('/pages/mine/settings/business-hours')">
          <text class="item-label">营业时间</text>
          <view class="item-right">
            <text class="item-value">{{shopInfo.businessHours}}</text>
            <text class="item-arrow">></text>
          </view>
        </view>
        <view class="settings-item" @click="navigateTo('/pages/mine/settings/address')">
          <text class="item-label">店铺地址</text>
          <view class="item-right">
            <text class="item-value">{{shopInfo.address}}</text>
            <text class="item-arrow">></text>
          </view>
        </view>
      </view>
    </view>

    <!-- 经营设置 -->
    <view class="settings-group">
      <view class="group-title">经营设置</view>
      <view class="settings-list">
        <view class="settings-item" @click="navigateTo('/pages/mine/settings/delivery')">
          <text class="item-label">配送设置</text>
          <view class="item-right">
            <text class="item-value">配送范围、起送价等</text>
            <text class="item-arrow">></text>
          </view>
        </view>
        <view class="settings-item" @click="navigateTo('/pages/mine/settings/payment')">
          <text class="item-label">支付设置</text>
          <view class="item-right">
            <text class="item-value">支付方式、结算周期</text>
            <text class="item-arrow">></text>
          </view>
        </view>
        <view class="settings-item" @click="navigateTo('/pages/mine/settings/notification')">
          <text class="item-label">通知设置</text>
          <view class="item-right">
            <text class="item-value">订单通知、系统通知</text>
            <text class="item-arrow">></text>
          </view>
        </view>
      </view>
    </view>

    <!-- 账户安全 -->
    <view class="settings-group">
      <view class="group-title">账户安全</view>
      <view class="settings-list">
        <view class="settings-item" @click="navigateTo('/pages/mine/settings/password')">
          <text class="item-label">修改密码</text>
          <text class="item-arrow">></text>
        </view>
        <view class="settings-item" @click="navigateTo('/pages/mine/settings/phone')">
          <text class="item-label">手机号绑定</text>
          <view class="item-right">
            <text class="item-value">{{shopInfo.phone}}</text>
            <text class="item-arrow">></text>
          </view>
        </view>
      </view>
    </view>
  </view>
</template>

<script>
export default {
  data() {
    return {
      shopInfo: {
        name: '川味小馆',
        businessHours: '09:00-22:00',
        address: '成都市武侯区科华北路65号',
        phone: '138****8888'
      }
    }
  },
  methods: {
    navigateTo(url) {
      uni.navigateTo({
        url: url
      })
    }
  }
}
</script>

<style>
.settings-container {
  min-height: 100vh;
  background-color: #f5f5f5;
  padding: 20rpx;
}

.settings-group {
  background-color: #ffffff;
  border-radius: 12rpx;
  margin-bottom: 20rpx;
  overflow: hidden;
}

.group-title {
  font-size: 28rpx;
  color: #333;
  font-weight: bold;
  padding: 20rpx;
  border-bottom: 1rpx solid #f5f5f5;
}

.settings-list {
  padding: 0 20rpx;
}

.settings-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 30rpx 0;
  border-bottom: 1rpx solid #f5f5f5;
}

.settings-item:last-child {
  border-bottom: none;
}

.item-label {
  font-size: 28rpx;
  color: #333;
}

.item-right {
  display: flex;
  align-items: center;
}

.item-value {
  font-size: 26rpx;
  color: #999;
  margin-right: 10rpx;
}

.item-arrow {
  color: #999;
  font-size: 28rpx;
}
</style> 